package com.niit.blog.mapper;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.github.pagehelper.Page;
import com.niit.blog.entity.Dto.CommentControDto;
import com.niit.blog.entity.domain.TbBlogComment;
import com.niit.blog.entity.page.PageReq;
import com.niit.blog.entity.page.PageReqreq;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
* @author 18512
* @description 针对表【tb_blog_comment】的数据库操作Mapper
* @createDate 2024-06-25 20:33:55
* @Entity .domain.TbBlogComment
*/
@Mapper
public interface TbBlogCommentMapper extends BaseMapper<TbBlogComment> {

    IPage<CommentControDto> selectComments(Page<CommentControDto> page, QueryWrapper<TbBlogComment> queryWrapper);



    IPage<CommentControDto> selectByPageWithoutCondition(Page<CommentControDto> page);

    List<CommentControDto> selectMyByPage(@Param("offset") int offset, @Param("pageSize") int pageSize);

    List<TbBlogComment> selectAll();

    List<CommentControDto> getPageList(@Param("pageReq") PageReqreq pageReq);

    int insertData(TbBlogComment data);

}




